var Checkbox = function(t, e, i) {
    i = i || {},
    this.settings = FrauenVsRefugees.extendObject({
        backgroundColor: 16777215,
        buttonColor: 16711680,
        width: 100,
        height: 32,
        buttonWidth: 32,
        buttonHeight: 30,
        value: !0
    }, i),
    this.knobFingerId = 0,
    Phaser.Sprite.call(this, game, t, e, "pixel"),
    this.onChange = new Phaser.Signal;
    var a = this.game.add.graphics(0, 0);
    a.beginFill(this.settings.backgroundColor),
    a.lineStyle(1, this.settings.backgroundColor, 1),
    a.drawRect(-1, 0, this.settings.width + 2, this.settings.height),
    a.endFill(),
    this.background = game.add.sprite(0, 0, "pixel"),
    this.background.addChild(a),
    this.addChild(this.background);
    var a = this.game.add.graphics(0, 0);
    a.beginFill(this.settings.buttonColor),
    a.lineStyle(1, this.settings.buttonColor, 1),
    a.drawRect(0, 0, this.settings.buttonWidth, this.settings.buttonHeight),
    a.endFill(),
    a.x = (this.settings.width - this.settings.buttonWidth) / 2,
    a.y = (this.settings.height - this.settings.buttonHeight) / 2,
    this.knob = game.add.sprite(0, 0, "pixel"),
    this.knob.addChild(a),
    this.addChild(this.knob),
    this.background.inputEnabled = !0,
    this.background.events.onInputDown.add(this.change, this),
    this.value = this.settings.value
}
;
Checkbox.prototype = Object.create(Phaser.Sprite.prototype),
Checkbox.prototype.constructor = Checkbox,
Checkbox.prototype.change = function() {
    this.settings.value = !this.settings.value,
    this.knob.visible = this.settings.value,
    this.onChange.dispatch(this.settings.value)
}